<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
</head>
<body>
	
	<script>
		function add(){
			console.log(arguments);
			var sum=0;
			for(var i=0;i<arguments.length;i++){
				sum+=arguments[i];
			}
			return sum;
		}

		document.write(add(1,2,3,4,5));

	</script>

</body>
</html>